package dto.RepairDetail;

import com.alibaba.fastjson.annotation.JSONField;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.sql.ResultSet;
import java.sql.SQLException;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;

@Data
@NoArgsConstructor
public class DetailDate {

    private Integer id;

    @JSONField(format = "yyyy-MM-dd")
    private Date date;

    private String deal;

    private String remarks;

    private List<String> names = new ArrayList<>();

    public DetailDate(ResultSet rs) throws SQLException {
        this.id = rs.getInt("id");
        this.date = rs.getDate("date");
        this.deal = rs.getString( "deal");
        this.remarks = rs.getString( "remarks");
    }


}
